require("../../common/vendor.js"), (global.webpackJsonp = global.webpackJsonp || []).push([ [ "pagesA/pages/userA/change" ], {
    "0fd9": function(e, n, t) {
        t.r(n);
        var a, o = t("2ed9"), i = t.n(o);
        for (a in o) "default" !== a && function(e) {
            t.d(n, e, function() {
                return o[e];
            });
        }(a);
        n.default = i.a;
    },
    "2ed9": function(e, t, u) {
        (function(a) {
            Object.defineProperty(t, "__esModule", {
                value: !0
            }), t.default = void 0;
            var e, o = (e = u("a34a")) && e.__esModule ? e : {
                default: e
            };
            function c(e, n, t, a, o, i, u) {
                try {
                    var r = e[i](u), c = r.value;
                } catch (e) {
                    return t(e), 0;
                }
                r.done ? n(c) : Promise.resolve(c).then(a, o);
            }
            var i = getApp(), n = {
                data: function() {
                    return {
                        module_name: i.globalData.module_name,
                        showAlert_login: !1,
                        userinfo: a.getStorageSync("userinfo"),
                        setting: a.getStorageSync("setting"),
                        wxCode: "",
                        systemtype: "",
                        num: "",
                        logs: [],
                        page: 1,
                        loadingType: 0
                    };
                },
                components: {
                    gracePage: function() {
                        u.e("graceUI/components/gracePage").then(function() {
                            return resolve(u("1021"));
                        }.bind(null, u)).catch(u.oe);
                    },
                    graceLoading: function() {
                        u.e("graceUI/components/graceLoading").then(function() {
                            return resolve(u("1d04"));
                        }.bind(null, u)).catch(u.oe);
                    },
                    graceEmptyNew: function() {
                        u.e("graceUI/components/graceEmptyNew").then(function() {
                            return resolve(u("f8df"));
                        }.bind(null, u)).catch(u.oe);
                    }
                },
                props: {},
                onShow: function() {
                    a.hideLoading();
                },
                onLoad: function(e) {
                    var r, t = this;
                    return r = o.default.mark(function e() {
                        var n;
                        return o.default.wrap(function(e) {
                            for (;;) switch (e.prev = e.next) {
                              case 0:
                                return e.next = 2, t.$onLaunched;

                              case 2:
                                (n = t).setting = a.getStorageSync("setting"), n.tabBar = a.getStorageSync("tabbar"), 
                                n.userinfo = a.getStorageSync("userinfo"), a.hideLoading(), t.module_name = i.globalData.module_name, 
                                t.dataLoad();

                              case 11:
                              case "end":
                                return e.stop();
                            }
                        }, e);
                    }), function() {
                        var e = this, u = arguments;
                        return new Promise(function(n, t) {
                            var a = r.apply(e, u);
                            function o(e) {
                                c(a, n, t, o, i, "next", e);
                            }
                            function i(e) {
                                c(a, n, t, o, i, "throw", e);
                            }
                            o(void 0);
                        });
                    }();
                },
                onPullDownRefresh: function() {
                    this.user_info(), this.logs = [], this.page = 1, this.loadingType = 0, this.dataLoad();
                },
                onReachBottom: function() {
                    1 != this.loadingType && 2 != this.loadingType && this.dataLoad();
                },
                methods: {
                    info: function() {
                        a.navigateTo({
                            url: "info"
                        });
                    },
                    user_info: function() {
                        var n = this, e = i.globalData.util.url("entry/wxapp/userinfonew", {
                            m: i.globalData.module_name
                        });
                        a.request({
                            url: e,
                            method: "POST",
                            header: {
                                "content-type": "application/x-www-form-urlencoded"
                            },
                            data: {
                                openid: a.getStorageSync("openid")
                            },
                            success: function(e) {
                                a.setStorageSync("userinfo", e.data.data), n.userinfo = e.data.data, a.stopPullDownRefresh();
                            }
                        });
                    },
                    dataLoad: function() {
                        var n = this, e = i.globalData.util.url("entry/wxapp/api", {
                            m: i.globalData.module_name,
                            o: "creditlog"
                        });
                        this.loadingType = 1, a.request({
                            url: e,
                            method: "POST",
                            header: {
                                "content-type": "application/x-www-form-urlencoded"
                            },
                            data: {
                                openid: a.getStorageSync("openid"),
                                page: this.page
                            },
                            success: function(e) {
                                1 == e.data.status && (e = i.globalData.crypt.Decrypt(e.data.data.data, e.data.data.key), 
                                e = JSON.parse(e), console.log(e), n.logs = n.logs.concat(e.logs), n.logs = n.logs, 
                                n.page > e.total ? 0 == n.logs.length ? n.loadingType = 4 : n.loadingType = 2 : n.page == e.total ? n.loadingType = 2 : (n.page = n.page + 1, 
                                n.loadingType = 0, n.page = n.page));
                            }
                        });
                    },
                    numChange: function(e) {
                        this.num = e.target.value;
                    },
                    clearInput: function() {
                        this.num = "";
                    },
                    formSubmit: function(e) {
                        var n = e.detail.value, e = i.globalData.util.url("entry/wxapp/api", {
                            m: i.globalData.module_name,
                            o: "creditchange"
                        });
                        "" != n.num && 0 != n.num ? (a.showLoading({
                            title: "加载中...",
                            mask: !0
                        }), a.request({
                            url: e,
                            method: "POST",
                            header: {
                                "content-type": "application/x-www-form-urlencoded"
                            },
                            data: {
                                openid: a.getStorageSync("openid"),
                                num: n.num
                            },
                            success: function(e) {
                                1 == e.data.status ? (a.hideLoading(), a.showToast({
                                    title: e.data.msg
                                })) : (a.hideLoading(), a.showToast({
                                    title: e.data.msg,
                                    icon: "none"
                                }));
                            }
                        })) : a.showToast({
                            title: "请输入兑换金额",
                            icon: "none"
                        });
                    }
                }
            };
            t.default = n;
        }).call(this, u("543d").default);
    },
    3358: function(e, n, t) {},
    "5ae4": function(e, n, t) {
        t.d(n, "b", function() {
            return a;
        }), t.d(n, "c", function() {
            return o;
        }), t.d(n, "a", function() {});
        var a = function() {
            this.$createElement;
            this._self._c;
        }, o = [];
    },
    "797c": function(e, n, t) {
        var a = t("3358");
        t.n(a).a;
    },
    a22f: function(e, n, t) {
        t.r(n);
        var a, o = t("5ae4"), i = t("0fd9");
        for (a in i) "default" !== a && function(e) {
            t.d(n, e, function() {
                return i[e];
            });
        }(a);
        t("797c");
        var u = t("f0c5"), o = Object(u.a)(i.default, o.b, o.c, !1, null, null, null, !1, o.a, void 0);
        n.default = o.exports;
    },
    ab3f: function(e, n, t) {
        (function(e) {
            function n(e) {
                return e && e.__esModule ? e : {
                    default: e
                };
            }
            t("0cda"), n(t("66fd")), e(n(t("a22f")).default);
        }).call(this, t("543d").createPage);
    }
}, [ [ "ab3f", "common/runtime", "common/vendor" ] ] ]);